package com.billdowney;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.domain.EntityScan;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;

import com.billdowney.StartUpApplication;

/**
 * @Description: 服务开启实现类
 * @author: 唐路钧
 * @date: 2018年12月27日 下午5:21:04
 */
@EnableJpaRepositories("com.billdowney.dao") // JPA扫描该包路径下的Repositorie
@EntityScan("com.billdowney.entity") // 扫描实体类
//@EnableScheduling
@SpringBootApplication(scanBasePackages = { "com.billdowney" })
public class StartUpApplication extends SpringBootServletInitializer {

	@Override
	protected SpringApplicationBuilder configure(SpringApplicationBuilder application) {
		return application.sources(StartUpApplication.class);
	}

	public static void main(String[] args) {
		SpringApplication.run(StartUpApplication.class, args);
	}
}
